Enumerating permutations sortable by k passes through a pop-stack

نویسندگان

  • Anders Claesson
  • Bjarki Ágúst Guðmundsson
چکیده

In an exercise in the first volume of his famous series of books, Knuth considered sorting permutations by passing them through a stack. Many variations of this exercise have since been considered, including allowing multiple passes through the stack and using different data structures. We are concerned with a variation using pop-stacks that was introduced byAvis andNewborn in 1981. Let Pk(x) be the generating function for the permutations sortable by k passes through a pop-stack. The generating function P2(x) was recently given by Pudwell and Smith (the case k = 1 being trivial). We show that Pk(x) is rational for any k. Moreover, we give an algorithm to derive Pk(x), and using it we determine the generating functions Pk(x) for k ≤ 6.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

A Stack and a Pop Stack in Series

We study sorting machines consisting of a stack and a pop stack in series, with or without a queue between them. While there are, a priori, four such machines, only two are essentially different: a pop stack followed directly by a stack, and a pop stack followed by a queue and then by a stack. In the former case, we obtain complete answers for the basis and enumeration of the sortable permutati...

متن کامل

A stack and pop stack in series

We study sorting machines consisting of a stack and a pop stack in series, with or without a queue between them. While there are, a priori, four such machines, only two are essentially different: a pop stack followed directly by a stack, and a pop stack followed by a queue and then by a stack. In the former case, we obtain complete answers for the basis and enumeration of the sortable permutati...

متن کامل

Sorted and or sortable permutations

In his Ph D thesis Julian West studied in depth a map that acts on permutations of the symmetric group Sn by partially sorting them through a stack The main motivation of this paper is to characterize and count the permutations of Sn which we call sorted permutations This is equivalent to counting preorders of increasing binary trees We rst nd a local characterization of sorted permutations The...

متن کامل

2-stack Sortable Permutations with a given Number of Runs

Using earlier results we prove a formula for the number W(n,k) of 2stack sortable permutations of length n with k runs, or in other words, k − 1 descents. This formula will yield the suprising fact that there are as many 2-stack sortable permutations with k−1 descents as with k−1 ascents. We also prove that W(n,k) is unimodal in k, for any fixed n.

متن کامل

On the Stack Sortable and Pushpopable Permutations

This work proposes an O(log n) time parallel algorithm for testing whether a permutation is stack sortable or not by O(n) processors under the PRAM EREW computational model. Additionally, the number of permutations which are both stack sortable and pushpopable is also discussed, and an equality is finally obtained, which combines n!, 2, Cn, and Un together where Cn is the Catalan number and Un ...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2017